//定义组件
define(function (require, exports, module) {

    var sTpl = require('./index.html');
    var css = require('./index.css');

    var myMixin = require('mixins/mixins.js');

    var vueComponent = Vue.extend({
        template: sTpl,
        mixins: [myMixin],
        props: {
            "show": {
                default: true
            },
            "title": {
                default: ''
            },
            'headShow': {
                default: true
            },
            'collapse': {
                default: false
            },
            'noPadding': {
                default: false
            }
        },
        data: function () {
            return {


            }
        },
        methods: {
            toggleShow: function (to) {
                if (to) {
                    this.collapse = to;
                } else {
                    this.collapse = !this.collapse;
                }

                this.$emit("toggleShow", this.collapse);
            },
            headerOnClick: function () {
                this.toggleShow();
            }
        }
    });

    Vue.component('m-login-card', vueComponent); //都全局注册 同时exports
    module.exports = vueComponent;
});